package com.example.controller;

import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.HashSet;
import java.util.Map;
import java.util.Set;

/**
 * @author wuyuhong
 * @date 2021/06/08 22:25
 **/
@RestController
public class HelloController {

@GetMapping("/load")
    public void hello(Model model){
    Map<String,Object>datamap=model.asMap();
    Map<String, String>map= (Map<String, String>) datamap.get("info");
  Set<String> set =   map.keySet();
    for (String s:
         set) {
        System.out.println(s+"----------"+map.get(s));

    }
}
}
